package com.example.snakefinal;

import com.google.gson.Gson;

public class JsonUtil {

    public static final Gson json = new Gson();

    public static String toStr(Object object) {
        return json.toJson(object);
    }

    public static  <T> T fromStr(String str, Class<T> tClass) {
        return json.fromJson(str, tClass);
    }
}
